import java.util.Random;

public class Game {
    public static void main(String[] args) {
        Exercise e = new Exercise();
        double prob[] = new double[6];
        for(int i=0;i<1000000;i++){
            int n=e.rand6_v2();
            prob[n-1]++;
        }
        for(int i=0;i<6;i++){
            System.out.println("第"+(i+1)+"次投掷，概率为："+prob[i]/1000000);
        }
    }
}
class Exercise{
    Random random=new Random(2077);
    int rand6_v1(){
        return random.nextInt(6)+1;
    }
    int rand6_v2(){
        return (int)(Math.random()*6)+1;
    }
}
